home *** CD-ROM | disk | FTP | other *** search
/ Windows 3-Pak 2 - Disc 2 / Infomagic - Windows 3-Pak Volume 2 (Disc 2 of 3).iso / Chat---IRC / TURBOIRC.ZIP / data1.cab / TurboIRC_Scripts / EGUESSGAME.txt < prev    next >
Text File  |  1999-05-05  |  999b  |  46 lines

  1. // Guess Game TurboIRC Script
  2. // By Chourdakis Michael ⌐ 1998
  3. staticint Num = Random(1000)
  4. staticint Tries = 0
  5.  
  6.  
  7. if (strnicmp("$3*",":!number ",8)!= 0)
  8.  return
  9. endif
  10.  
  11. // in a game !
  12. int L = atoi("$4")
  13. if (L == Num)
  14.  /display $channel ConGrATuLaTiOnS you HaVe FOUND it !! It WaS %Num% !
  15.  /display $channel *******GAME OVER*******
  16.  /destroystaticvariable Num
  17.  /destroystaticvariable Tries
  18.  /_event GUESSGAME 0 0 0 *
  19.  return
  20. endif
  21.  
  22. if (L > Num)
  23.  /display $channel Uhhhow ! You ArE TOO HiGH !
  24.  Tries += 1
  25.  goto FoundT
  26. endif
  27.  
  28. if (L < Num)
  29.  /display $channel Uhhhow ! You ArE TOO LoW !
  30.  Tries += 1
  31.  goto FoundT
  32. endif
  33.  
  34. :FoundT
  35.  
  36. if (Tries == 10)
  37.  /display $channel UHHHOH you didn't find the SecReT NuMbER was %Num% !
  38.  /display $channel *******GAME OVER*******
  39.  /destroystaticvariable Num
  40.  /destroystaticvariable Tries
  41.  /_event GUESSGAME 0 0 0 *
  42. else
  43.  int V = 10 - Tries
  44.  /display $channel WaTcH It You have OnLy %V% tries left !
  45. endif
  46.